#########################################################################################
## 
## Hack Title:    Display a (new) field in topics
## Author:        Acid
##
## Description:   If you want to display a (new) field in topic view..
##		  If you want to add several (new) fields to topic view duplicate
##		  the following steps and change "info" (be aware of the spelling).
##		  The field "info" is just an example.
##
## Files to edit: 2
##		  viewtopic.php
##                templates/xxx/viewtopic_body.tpl
##
#########################################################################################
## 
## Installation/Author Notes: 
## First always backup the files that you're going to edit. 
## 
#########################################################################################
# 
#-----[ OPEN ]------------------------------------------
#  
# viewtopic.php
# 
#-----[ FIND (just a quote) ]---------------------------------------------------
# 
$sql = "SELECT u.

# 
#-----[ IN-LINE FIND ]---------------------------------------------------
# 
u.user_from

# 
#-----[ IN-LINE ADD ]---------------------------------------------------
# 
, u.user_info

# 
#-----[ FIND ]---------------------------------------------------
# 
	$poster_from = ( $postrow[$i]['user_from'] && $postrow[$i]['user_id'] != ANONYMOUS ) ? $lang['Location'] . ': ' . $postrow[$i]['user_from'] : '';

# 
#-----[ BELOW ADD ]---------------------------------------------------
# 
	// only if youre using an option field (delete // before the next 2 lines)
	// $info = ( $postrow[$i]['user_info'] == '0' ) ? $lang['No'] : $lang['Yes'];
	// $poster_info = ( $info && $postrow[$i]['user_id'] != ANONYMOUS ) ? $lang['Info'] . ': ' . $info : '';
	// and uncomment the next line (add // before)
	$poster_info = ( $postrow[$i]['user_info'] && $postrow[$i]['user_id'] != ANONYMOUS ) ? $lang['Info'] . ': ' . $postrow[$i]['user_info'] : '';

# 
#-----[ FIND ]---------------------------------------------------
# 
		'POSTER_FROM' => $poster_from,

# 
#-----[ BELOW ADD ]---------------------------------------------------
# 
		'POSTER_INFO' => $poster_info,



# 
#-----[ OPEN ]------------------------------------------
#  
# templates/xxx/viewtopic_body.tpl
# 
#-----[ FIND ]---------------------------------------------------
# 
{postrow.POSTER_FROM}

# 
#-----[ AFTER ADD ]---------------------------------------------------
# 
<br />{postrow.POSTER_INFO}

#########################################################################################
#########################################################################################
#########################################################################################